from tutor.scripts import *
from tutor.plugins.sympy import *

with display_block('Entradas'):
    # seleciona pontos
    f = oneof(cos, sin, exp)                 
    F = Lambda(x, f(x).integrate())
    n = One * oneof(1/Three, Half, Three/2, 2, 3)
    m = One/(n-1)
    b = One * oneof(Half, 1, Three/2, 2)
    if f != exp:
        c = oneof(pi/6, pi/4, pi/3, pi/2, 3*pi/4)
    else:
        c = log(oneof(2, 3, 4, 5, 6))
    a = c/b**n

    lim_y = c
    lim_sup = b
    lim_inf = y**m
    func = f(a * x**n)
    

with display_block('Respostas'):
    correta = 1/(a*n) * (F(c) - F(0))
    troca_limites = - correta
    dis_1 = 1/(a*n) * (F(a * b**(n/(n-1))) - F(0))
    dis_2 = b**n * f(a*b**n)
    dis_3 = c/(a*n)
    neg_dis_1 = - dis_1 
    neg_dis_2 = - dis_2
    neg_dis_3 = - dis_3
assert correta != 0